#ifndef _TREE_H_
#define _TREE_H_
#include "globals.h"

/* FUNC: new_stmt_node creates a new statement node for syntax tree
 * construction
 */
tree new_stmt_node(stmt_kind);

/* FUNC: new_expr_node creates a new expression node for syntax tree
 * construction */
tree new_expr_node(expr_kind);

/* FUNC: str_copy invokes strdup() and adds some error report  */
char *str_copy(char *);

/* FUNC: tree_print print the syntax tree for debug and error detects
 * use */
void tree_print(tree);

/* FUNC: add the t1 to the end of t and return the tree's head  */
tree add_tree_end(tree t, tree t1);


#endif //tree_h
